package com.hubei.car.handler;

/**
 * 自定义异常
 * @author luokangtao
 * @create 2019-07-23 17:33
 */
public class BaseException extends RuntimeException {
    private int statusCode;
    private String message;
    //提供无参数的构造方法
    public BaseException(){};
    //提供一个有参数的构造方法，可自动生成
    public BaseException(String message){this.message = message;}
    //提供一个有参数的构造方法，可自动生成
    public BaseException(int statusCode,String message){this.statusCode=statusCode;this.message = message;}

    public int getStatusCode() {
        return statusCode;
    }

    public void setStatusCode(int statusCode) {
        this.statusCode = statusCode;
    }

    @Override
    public String getMessage() {
        return message;
    }
    public void setMessage(String message) {
        this.message = message;
    }
}
